#include<iostream>
using namespace std;
class student {
private:
	char name[10];
	char number[20];
	char gender[10];
	char college[20];
	char tele[20];
public:
	void my_input() {
		cin >> name >> number >> gender >> college >> tele;
	}
	void my_print() {
		cout << name << endl;
	}
};
int main()
{
	int t;
	cin >> t;
	class student* tmp = new class student[t];
	for (int i = 0; i < t; i++) {
		(tmp + i)->my_input();
	}
	for (int i = 0; i < t; i++) {
		(tmp + i)->my_print();
	}
	return 0;
}